<%-- 
    Document   : login
    Created on : 17/01/2013, 08:53:03 PM
    Author     : Administrador
--%>

<%@page import="NM_BD.Conexion"%>
<%@page contentType="text/html" pageEncoding="UTF-8"%>
<!DOCTYPE html>
<html>
    <head>
        <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
        <title>JSP Page</title>
        <meta http-equiv="X-UA-Compatible" content="IE=EmulateIE7" />
        <link href="css/styles_proyecto_gnm.css" rel="stylesheet" type="text/css" /> 
        <script type="text/javascript" src="js/javascript_proyecto_gnm.js" ></script>
        <script language="javascript">
            //aqui meto javascript
            function iniciarusuario(){
                document.getElementById("TxtUsuario").value = 'ejemplo@dominio.com';
                document.getElementById("TxtUsuario").style.color='#c8c8c8';
                
                document.getElementById("TxtClave").type='text';
                document.getElementById("TxtClave").style.color='#c8c8c8';
                document.getElementById("TxtClave").value = 'Contraseña';
                //alert("dfsdf");
            }          
         
            function btnIniciar(){
                var contexto = "<%= request.getContextPath()%>";
                document.login.action = contexto+"/NM_Usuario";
                //document.login.action = contexto+"/app_sabre/reserva.jsp";
                document.login.submit();
                return true;               
            }  
        </script>		

    </head>
    <body onload="iniciarusuario();">
        <form name="login" action="NM_Usuario" method="post">
            <table style='width:90%;height:444px' align="center" cellpadding="0" cellspacing="13">
                <tr>
                    <td style='width:60%'>
                        <table border="0" cellpadding="0" cellspacing="0" style='width:100%;height:400px'>
                            <tr>
                                <td align="center" valign="middle"><img src="img/img1.png"></td>
                            </tr>
                        </table>

                    </td>
                    <td align="center" valign="middle" style='width:30%'><table>
                            <tr>
                                <td><div class="titulologin">Iniciar Sesi&oacute;n</div></td>
                            </tr>
                            <tr>
                                <td><input type="text" id="TxtUsuario" name="TxtUsuario" class="cajatexto" value="" onFocus="cleartext1(this);" onBlur="startext1(this);" onkeypress="return event.keyCode!=13" /></td>
                            </tr>
                            <tr>
                                <td>
                                    <input type="password" id="TxtClave" name="TxtClave" class="cajatexto" value="" onFocus="cleartext2(this);" onBlur="startext2(this);" onkeypress="return event.keyCode!=13" /></td>
                            </tr>
                            <tr>
                                <td>&nbsp;</td>
                            </tr>
                            <tr>
                                <td><input name="Btn_Aceptar" class="botones" id="Btn_Aceptar" style="width:120px; height:35px;" type="button" value="Iniciar" onclick="javascript:btnIniciar();"/></td>
                            </tr>
                            <tr>
                                <td><div class="titulologin">           <% if (request.getAttribute("error") != null) {

                                        %>   
                                        <%=  request.getAttribute("error")%>
                                        <%  }%></div></td>
                            </tr>
                        </table></td>
                </tr>
            </table>

        </form>
    </body>
</html>
